package me.json;

import java.io.File;
import java.io.IOException;
import java.util.ArrayList;
import java.util.List;

import me.json.model.City;
import me.json.model.Province;

import com.fasterxml.jackson.core.JsonEncoding;
import com.fasterxml.jackson.core.JsonFactory;
import com.fasterxml.jackson.core.JsonGenerator;
import com.fasterxml.jackson.core.JsonParseException;
import com.fasterxml.jackson.core.JsonParser;
import com.fasterxml.jackson.core.JsonToken;
import com.fasterxml.jackson.databind.ObjectMapper;

public class CountryFactroy {

	private static final String JSON_FILE = "json/country.json";

	public static void make() {
		try {
			File file = new File(JSON_FILE);
			if (file.exists() && file.isFile()) {
				ObjectMapper mapper = new ObjectMapper();
				JsonFactory jsonFactory = new JsonFactory();
				JsonGenerator jsonGenerator = jsonFactory.createGenerator(file,
						JsonEncoding.UTF8);
				mapper.writeValue(jsonGenerator, makeProvinces());

			}
		} catch (Exception e) {
			e.printStackTrace();
		}
	}

	public static void parser() {

		JsonFactory f = new JsonFactory();
		try {
			JsonParser jsonParser = f.createParser(new File(JSON_FILE));
			List<Province> list = null;
			if (jsonParser.getCurrentToken() != JsonToken.VALUE_NULL) {

				list = new ArrayList<Province>();
				while (jsonParser.nextToken() != JsonToken.END_ARRAY) {
					Province province = Province.fromJsonParser(jsonParser);
					list.add(province);
					jsonParser.skipChildren();
				}

			}
			if (list != null && list.size() > 0) {
				for (Province province : list) {
					System.out.println(province.getName());
				}
			}

		} catch (JsonParseException e) {
			e.printStackTrace();
		} catch (IOException e) {
			e.printStackTrace();
		}
	}

	public static void main(String[] args) {
		make();
		parser();
	}

	private static List<Province> makeProvinces() {
		List<Province> provinces = new ArrayList<Province>();
		// '11'=>array('name'=>'北京','city'=>array('1'=>'东城','2'=>'西城','3'=>'崇文','4'=>'宣武','5'=>'朝阳','6'=>'丰台','7'=>'石景山','8'=>'海淀','9'=>'门头沟','11'=>'房山','12'=>'通州','13'=>'顺义','21'=>'昌平','24'=>'大兴','26'=>'平谷','27'=>'怀柔','28'=>'密云','29'=>'延庆',)),
		List<City> bj = new ArrayList<City>();
		bj.add(new City(1, "东城"));
		bj.add(new City(2, "西城"));
		bj.add(new City(3, "崇文"));
		bj.add(new City(4, "宣武"));
		bj.add(new City(5, "朝阳"));
		bj.add(new City(6, "丰台"));
		bj.add(new City(7, "石景山"));
		bj.add(new City(8, "海淀"));
		bj.add(new City(9, "门头沟"));
		bj.add(new City(11, "房山"));
		bj.add(new City(12, "通州"));
		bj.add(new City(13, "顺义"));
		bj.add(new City(21, "昌平"));
		bj.add(new City(24, "大兴"));
		bj.add(new City(26, "平谷"));
		bj.add(new City(27, "怀柔"));
		bj.add(new City(28, "密云"));
		bj.add(new City(29, "延庆"));
		provinces.add(new Province(11, "北京", bj));

		/*
		 * '12'=>array('name'=>'天津','city'=>array('1'=>'和平','2'=>'河东','3'=>'河西','4'=>'南开','5'=>'河北','6'=>'红桥','7'=>'塘沽','8'=>'汉沽','9'=>'大港','10'=>'东丽','11'=>'西青','12'=>'津南','13'=>'北辰','21'=>'宁河','22'=>'武清','23'=>'静海','24'=>'宝坻','25'=>'蓟县',)),
		 */
		List<City> tj = new ArrayList<City>();
		tj.add(new City(1, "和平"));
		tj.add(new City(2, "河东"));
		tj.add(new City(3, "河西"));
		tj.add(new City(4, "南开"));
		tj.add(new City(5, "河北"));
		tj.add(new City(6, "红桥"));
		tj.add(new City(7, "塘沽"));
		tj.add(new City(8, "汉沽"));
		tj.add(new City(9, "大港"));
		tj.add(new City(10, "东丽"));
		tj.add(new City(11, "西青"));
		tj.add(new City(12, "津南"));
		tj.add(new City(13, "北辰"));
		tj.add(new City(21, "宁河"));
		tj.add(new City(22, "武清"));
		tj.add(new City(23, "静海"));
		tj.add(new City(24, "宝坻"));
		tj.add(new City(25, "蓟县"));
		provinces.add(new Province(12, "天津", tj));

		/* '13'=>array('name'=>'河北','city'=>array('1'=>'石家庄','2'=>'唐山','3'=>'秦皇岛','4'=>'邯郸','5'=>'邢台','6'=>'保定','7'=>'张家口','8'=>'承德','9'=>'沧州','10'=>'廊坊','11'=>'衡水',)), */
		List<City> hb = new ArrayList<City>();
		hb.add(new City(1, "石家庄"));
		hb.add(new City(2, "唐山"));
		hb.add(new City(3, "秦皇岛"));
		hb.add(new City(4, "邯郸"));
		hb.add(new City(5, "邢台"));
		hb.add(new City(6, "保定"));
		hb.add(new City(7, "张家口"));
		hb.add(new City(8, "承德"));
		hb.add(new City(9, "沧州"));
		hb.add(new City(10, "廊坊"));
		hb.add(new City(11, "衡水"));
		provinces.add(new Province(13, "河北", hb));

		/*
		 * '14'=>array('name'=>'山西','city'=>array('1'=>'太原','2'=>'大同','3'=>'阳泉','4'=>'长治','5'=>'晋城','6'=>'朔州','7'=>'晋中','8'=>'运城','9'=>'忻州','10'=>'临汾','11'=>'吕梁',)),
		 */
		List<City> sx = new ArrayList<City>();
		sx.add(new City(1, "太原"));
		sx.add(new City(2, "大同"));
		sx.add(new City(3, "阳泉"));
		sx.add(new City(4, "长治"));
		sx.add(new City(5, "晋城"));
		sx.add(new City(6, "朔州"));
		sx.add(new City(7, "晋中"));
		sx.add(new City(8, "运城"));
		sx.add(new City(9, "忻州"));
		sx.add(new City(10, "临汾"));
		sx.add(new City(11, "吕梁"));
		provinces.add(new Province(14, "山西", sx));

		/* '15'=>array('name'=>'内蒙古','city'=>array('1'=>'呼和浩特','2'=>'包头','3'=>'乌海','4'=>'赤峰','5'=>'通辽','6'=>'鄂尔多斯','7'=>'呼伦贝尔','8'=>'巴彦淖尔','9'=>'乌兰察布','22'=>'兴安','25'=>'锡林郭勒','29'=>'阿拉善',)), */
		List<City> nmg = new ArrayList<City>();
		nmg.add(new City(1, "呼和浩特"));
		nmg.add(new City(2, "包头"));
		nmg.add(new City(3, "乌海"));
		nmg.add(new City(4, "赤峰"));
		nmg.add(new City(5, "通辽"));
		nmg.add(new City(6, "鄂尔多斯"));
		nmg.add(new City(7, "呼伦贝尔"));
		nmg.add(new City(8, "巴彦淖尔"));
		nmg.add(new City(9, "乌兰察布"));
		nmg.add(new City(22, "兴安"));
		nmg.add(new City(25, "锡林郭勒"));
		nmg.add(new City(29, "阿拉善"));
		provinces.add(new Province(15, "内蒙古", nmg));

		/* '21'=>array('name'=>'辽宁','city'=>array('1'=>'沈阳','2'=>'大连','3'=>'鞍山','4'=>'抚顺','5'=>'本溪','6'=>'丹东','7'=>'锦州','8'=>'营口','9'=>'阜新','10'=>'辽阳','11'=>'盘锦','12'=>'铁岭','13'=>'朝阳','14'=>'葫芦岛',)), */
		List<City> ln = new ArrayList<City>();
		ln.add(new City(1, "沈阳"));
		ln.add(new City(2, "大连"));
		ln.add(new City(3, "鞍山"));
		ln.add(new City(4, "抚顺"));
		ln.add(new City(5, "本溪"));
		ln.add(new City(6, "丹东"));
		ln.add(new City(7, "锦州"));
		ln.add(new City(8, "营口"));
		ln.add(new City(9, "阜新"));
		ln.add(new City(10, "辽阳"));
		ln.add(new City(11, "盘锦"));
		ln.add(new City(12, "铁岭"));
		ln.add(new City(13, "朝阳"));
		ln.add(new City(14, "葫芦岛"));
		provinces.add(new Province(21, "辽宁", ln));

		/* '22'=>array('name'=>'吉林','city'=>array('1'=>'长春','2'=>'吉林','3'=>'四平','4'=>'辽源','5'=>'通化','6'=>'白山','7'=>'松原','8'=>'白城','24'=>'延边',)), */
		List<City> jl = new ArrayList<City>();
		jl.add(new City(1, "长春"));
		jl.add(new City(2, "吉林"));
		jl.add(new City(3, "四平"));
		jl.add(new City(4, "辽源"));
		jl.add(new City(5, "通化"));
		jl.add(new City(6, "白山"));
		jl.add(new City(7, "松原"));
		jl.add(new City(8, "白城"));
		jl.add(new City(24, "延边"));
		provinces.add(new Province(22, "吉林", jl));

		/* '23'=>array('name'=>'黑龙江','city'=>array('1'=>'哈尔滨','2'=>'齐齐哈尔','3'=>'鸡西','4'=>'鹤岗','5'=>'双鸭山','6'=>'大庆','7'=>'伊春','8'=>'佳木斯','9'=>'七台河','10'=>'牡丹江','11'=>'黑河','12'=>'绥化','27'=>'大兴安岭',)), */
		List<City> hlj = new ArrayList<City>();
		hlj.add(new City(1, "哈尔滨"));
		hlj.add(new City(2, "齐齐哈尔"));
		hlj.add(new City(3, "鸡西"));
		hlj.add(new City(4, "鹤岗"));
		hlj.add(new City(5, "双鸭山"));
		hlj.add(new City(6, "大庆"));
		hlj.add(new City(7, "伊春"));
		hlj.add(new City(8, "佳木斯"));
		hlj.add(new City(9, "七台河"));
		hlj.add(new City(10, "牡丹江"));
		hlj.add(new City(11, "黑河"));
		hlj.add(new City(12, "绥化"));
		hlj.add(new City(27, "大兴安岭"));
		provinces.add(new Province(23, "黑龙江", hlj));

		/* '31'=>array('name'=>'上海','city'=>array('1'=>'黄浦','3'=>'卢湾','4'=>'徐汇','5'=>'长宁','6'=>'静安','7'=>'普陀','8'=>'闸北','9'=>'虹口','11'=>'杨浦','12'=>'闵行','13'=>'宝山','14'=>'嘉定','15'=>'浦东新','16'=>'金山','17'=>'松江','25'=>'南汇','26'=>'奉贤','29'=>'青浦','30'=>'崇明',)), */
		List<City> sh = new ArrayList<City>();
		sh.add(new City(1, "黄浦"));
		sh.add(new City(3, "卢湾"));
		sh.add(new City(4, "徐汇"));
		sh.add(new City(5, "长宁"));
		sh.add(new City(6, "静安"));
		sh.add(new City(7, "普陀"));
		sh.add(new City(8, "闸北"));
		sh.add(new City(9, "虹口"));
		sh.add(new City(11, "杨浦"));
		sh.add(new City(12, "闵行"));
		sh.add(new City(13, "宝山"));
		sh.add(new City(14, "嘉定"));
		sh.add(new City(15, "浦东新"));
		sh.add(new City(16, "金山"));
		sh.add(new City(17, "松江"));
		sh.add(new City(25, "南汇"));
		sh.add(new City(26, "奉贤"));
		sh.add(new City(29, "青浦"));
		sh.add(new City(30, "崇明"));
		provinces.add(new Province(31, "上海", sh));

		/* '32'=>array('name'=>'江苏','city'=>array('1'=>'南京','2'=>'无锡','3'=>'徐州','4'=>'常州','5'=>'苏州','6'=>'南通','7'=>'连云港','8'=>'淮安','9'=>'盐城','10'=>'扬州','11'=>'镇江','12'=>'泰州','13'=>'宿迁',)), */
		List<City> js = new ArrayList<City>();
		js.add(new City(1, "南京"));
		js.add(new City(2, "无锡"));
		js.add(new City(3, "徐州"));
		js.add(new City(4, "常州"));
		js.add(new City(5, "苏州"));
		js.add(new City(6, "南通"));
		js.add(new City(7, "连云港"));
		js.add(new City(8, "淮安"));
		js.add(new City(9, "盐城"));
		js.add(new City(10, "扬州'"));
		js.add(new City(11, "镇江"));
		js.add(new City(12, "泰州"));
		js.add(new City(13, "宿迁"));
		provinces.add(new Province(32, "江苏", js));

		/* '33'=>array('name'=>'浙江','city'=>array('1'=>'杭州','2'=>'宁波','3'=>'温州','4'=>'嘉兴','5'=>'湖州','6'=>'绍兴','7'=>'金华','8'=>'衢州','9'=>'舟山','10'=>'台州','11'=>'丽水',)), */
		List<City> zj = new ArrayList<City>();
		zj.add(new City(1, "杭州"));
		zj.add(new City(2, "宁波"));
		zj.add(new City(3, "温州"));
		zj.add(new City(4, "嘉兴"));
		zj.add(new City(5, "湖州"));
		zj.add(new City(6, "绍兴"));
		zj.add(new City(7, "金华"));
		zj.add(new City(8, "衢州"));
		zj.add(new City(9, "舟山"));
		zj.add(new City(10, "台州"));
		zj.add(new City(11, "丽水"));
		provinces.add(new Province(33, "浙江", zj));

		/* '34'=>array('name'=>'安徽','city'=>array('1'=>'合肥','2'=>'芜湖','3'=>'蚌埠','4'=>'淮南','5'=>'马鞍山','6'=>'淮北','7'=>'铜陵','8'=>'安庆','10'=>'黄山','11'=>'滁州','12'=>'阜阳','13'=>'宿州','14'=>'巢湖','15'=>'六安','16'=>'亳州','17'=>'池州','18'=>'宣城',)), */
		List<City> ah = new ArrayList<City>();
		ah.add(new City(1, "合肥"));
		ah.add(new City(2, "芜湖"));
		ah.add(new City(3, "蚌埠"));
		ah.add(new City(4, "淮南"));
		ah.add(new City(5, "马鞍山"));
		ah.add(new City(6, "淮北"));
		ah.add(new City(7, "铜陵"));
		ah.add(new City(8, "安庆"));
		ah.add(new City(10, "黄山"));
		ah.add(new City(11, "滁州"));
		ah.add(new City(12, "阜阳"));
		ah.add(new City(13, "宿州"));
		ah.add(new City(14, "巢湖"));
		ah.add(new City(15, "六安"));
		ah.add(new City(16, "亳州"));
		ah.add(new City(17, "池州"));
		ah.add(new City(18, "宣城"));
		provinces.add(new Province(34, "安徽", ah));

		/* '35'=>array('name'=>'福建','city'=>array('1'=>'福州','2'=>'厦门','3'=>'莆田','4'=>'三明','5'=>'泉州','6'=>'漳州','7'=>'南平','8'=>'龙岩','9'=>'宁德',)), */
		List<City> fj = new ArrayList<City>();
		fj.add(new City(1, "福州"));
		fj.add(new City(2, "厦门"));
		fj.add(new City(3, "莆田"));
		fj.add(new City(4, "三明"));
		fj.add(new City(5, "泉州"));
		fj.add(new City(6, "漳州"));
		fj.add(new City(7, "南平"));
		fj.add(new City(8, "龙岩"));
		fj.add(new City(9, "宁德"));
		provinces.add(new Province(35, "福建", fj));

		/* '36'=>array('name'=>'江西','city'=>array('1'=>'南昌','2'=>'景德镇','3'=>'萍乡','4'=>'九江','5'=>'新余','6'=>'鹰潭','7'=>'赣州','8'=>'吉安','9'=>'宜春','10'=>'抚州','11'=>'上饶',)), */
		List<City> jx = new ArrayList<City>();
		jx.add(new City(1, "南昌"));
		jx.add(new City(2, "景德镇"));
		jx.add(new City(3, "萍乡"));
		jx.add(new City(4, "九江"));
		jx.add(new City(5, "新余"));
		jx.add(new City(6, "鹰潭"));
		jx.add(new City(7, "赣州"));
		jx.add(new City(8, "吉安"));
		jx.add(new City(9, "宜春"));
		jx.add(new City(10, "抚州"));
		jx.add(new City(11, "上饶"));
		provinces.add(new Province(36, "江西", jx));

		/* '37'=>array('name'=>'山东','city'=>array('1'=>'济南','2'=>'青岛','3'=>'淄博','4'=>'枣庄','5'=>'东营','6'=>'烟台','7'=>'潍坊','8'=>'济宁','9'=>'泰安','10'=>'威海','11'=>'日照','12'=>'莱芜','13'=>'临沂','14'=>'德州','15'=>'聊城','16'=>'滨州','17'=>'菏泽',)), */
		List<City> sd = new ArrayList<City>();
		sd.add(new City(1, "济南"));
		sd.add(new City(2, "青岛"));
		sd.add(new City(3, "淄博"));
		sd.add(new City(4, "枣庄"));
		sd.add(new City(5, "东营"));
		sd.add(new City(6, "烟台"));
		sd.add(new City(7, "潍坊"));
		sd.add(new City(8, "济宁"));
		sd.add(new City(9, "泰安"));
		sd.add(new City(10, "威海"));
		sd.add(new City(11, "日照"));
		sd.add(new City(12, "莱芜"));
		sd.add(new City(13, "临沂"));
		sd.add(new City(14, "德州"));
		sd.add(new City(15, "聊城"));
		sd.add(new City(16, "滨州"));
		sd.add(new City(17, "菏泽"));
		provinces.add(new Province(37, "山东", sd));

		/* '41'=>array('name'=>'河南','city'=>array('1'=>'郑州','2'=>'开封','3'=>'洛阳','4'=>'平顶山','5'=>'安阳','6'=>'鹤壁','7'=>'新乡','8'=>'焦作','9'=>'濮阳','10'=>'许昌','11'=>'漯河','12'=>'三门峡','13'=>'南阳','14'=>'商丘','15'=>'信阳','16'=>'周口','17'=>'驻马店','18'=>'济源',)), */
		List<City> hn = new ArrayList<City>();
		hn.add(new City(1, "郑州"));
		hn.add(new City(2, "开封"));
		hn.add(new City(3, "洛阳"));
		hn.add(new City(4, "平顶山"));
		hn.add(new City(5, "安阳"));
		hn.add(new City(6, "鹤壁"));
		hn.add(new City(7, "新乡"));
		hn.add(new City(8, "焦作"));
		hn.add(new City(9, "濮阳"));
		hn.add(new City(10, "许昌"));
		hn.add(new City(11, "漯河"));
		hn.add(new City(12, "三门峡"));
		hn.add(new City(13, "南阳"));
		hn.add(new City(14, "商丘"));
		hn.add(new City(15, "信阳"));
		hn.add(new City(16, "周口"));
		hn.add(new City(17, "驻马店"));
		hn.add(new City(18, "济源"));
		provinces.add(new Province(41, "河南", hn));

		/* '42'=>array('name'=>'湖北','city'=>array('1'=>'武汉','2'=>'黄石','3'=>'十堰','5'=>'宜昌','6'=>'襄阳','7'=>'鄂州','8'=>'荆门','9'=>'孝感','10'=>'荆州','11'=>'黄冈','12'=>'咸宁','13'=>'随州','28'=>'恩施','94'=>'仙桃','95'=>'潜江','96'=>'天门','A21'=>'神农架',)), */
		List<City> hubei = new ArrayList<City>();
		hubei.add(new City(1, "武汉"));
		hubei.add(new City(2, "黄石"));
		hubei.add(new City(3, "十堰"));
		hubei.add(new City(5, "宜昌"));
		hubei.add(new City(6, "襄阳"));
		hubei.add(new City(7, "鄂州"));
		hubei.add(new City(8, "荆门"));
		hubei.add(new City(9, "孝感"));
		hubei.add(new City(10, "荆州"));
		hubei.add(new City(11, "黄冈"));
		hubei.add(new City(12, "咸宁"));
		hubei.add(new City(13, "随州"));
		hubei.add(new City(28, "恩施"));
		hubei.add(new City(94, "仙桃"));
		hubei.add(new City(95, "潜江"));
		hubei.add(new City(96, "天门"));
		hubei.add(new City("A21", "神农架"));
		provinces.add(new Province(42, "湖北", hubei));

		/* '43'=>array('name'=>'湖南','city'=>array('1'=>'长沙','2'=>'株洲','3'=>'湘潭','4'=>'衡阳','5'=>'邵阳','6'=>'岳阳','7'=>'常德','8'=>'张家界','9'=>'益阳','10'=>'郴州','11'=>'永州','12'=>'怀化','13'=>'娄底','31'=>'湘西',)), */
		List<City> hunan = new ArrayList<City>();
		hunan.add(new City(1, "长沙"));
		hunan.add(new City(2, "株洲"));
		hunan.add(new City(3, "湘潭"));
		hunan.add(new City(4, "衡阳"));
		hunan.add(new City(5, "邵阳"));
		hunan.add(new City(6, "岳阳"));
		hunan.add(new City(7, "常德"));
		hunan.add(new City(8, "张家界"));
		hunan.add(new City(9, "益阳"));
		hunan.add(new City(10, "郴州"));
		hunan.add(new City(11, "永州"));
		hunan.add(new City(12, "怀化"));
		hunan.add(new City(13, "娄底"));
		hunan.add(new City(31, "湘西"));
		provinces.add(new Province(43, "湖南", hunan));

		/* '44'=>array('name'=>'广东','city'=>array('1'=>'广州','2'=>'韶关','3'=>'深圳','4'=>'珠海','5'=>'汕头','6'=>'佛山','7'=>'江门','8'=>'湛江','9'=>'茂名','12'=>'肇庆','13'=>'惠州','14'=>'梅州','15'=>'汕尾','16'=>'河源','17'=>'阳江','18'=>'清远','19'=>'东莞','20'=>'中山','51'=>'潮州','52'=>'揭阳','53'=>'云浮',)), */
		List<City> gd = new ArrayList<City>();
		gd.add(new City(1, "广州"));
		gd.add(new City(2, "韶关"));
		gd.add(new City(3, "深圳"));
		gd.add(new City(4, "珠海"));
		gd.add(new City(5, "汕头"));
		gd.add(new City(6, "佛山"));
		gd.add(new City(7, "江门"));
		gd.add(new City(8, "湛江"));
		gd.add(new City(9, "茂名"));
		gd.add(new City(12, "肇庆"));
		gd.add(new City(13, "惠州"));
		gd.add(new City(14, "梅州"));
		gd.add(new City(15, "汕尾"));
		gd.add(new City(16, "河源"));
		gd.add(new City(17, "阳江"));
		gd.add(new City(18, "清远"));
		gd.add(new City(19, "东莞"));
		gd.add(new City(20, "中山"));
		gd.add(new City(51, "潮州"));
		gd.add(new City(52, "揭阳"));
		gd.add(new City(53, "云浮"));
		provinces.add(new Province(44, "广东", gd));

		/* '45'=>array('name'=>'广西','city'=>array('1'=>'南宁','2'=>'柳州','3'=>'桂林','4'=>'梧州','5'=>'北海','6'=>'防城港','7'=>'钦州','8'=>'贵港','9'=>'玉林','10'=>'百色','11'=>'贺州','12'=>'河池','13'=>'来宾','14'=>'崇左',)), */
		List<City> guangxi = new ArrayList<City>();
		guangxi.add(new City(1, "南宁"));
		guangxi.add(new City(2, "柳州"));
		guangxi.add(new City(3, "桂林"));
		guangxi.add(new City(4, "梧州"));
		guangxi.add(new City(5, "北海"));
		guangxi.add(new City(6, "防城港"));
		guangxi.add(new City(7, "钦州"));
		guangxi.add(new City(8, "贵港"));
		guangxi.add(new City(9, "玉林"));
		guangxi.add(new City(10, "百色"));
		guangxi.add(new City(11, "贺州"));
		guangxi.add(new City(12, "河池"));
		guangxi.add(new City(13, "来宾"));
		guangxi.add(new City(14, "崇左"));
		provinces.add(new Province(45, "广西", guangxi));

		/*
		 * '46'=>array('name'=>'海南','city'=>array('1'=>'海口','2'=>'三亚','91'=>'五指山','92'=>'琼海','93'=>'儋州','95'=>'文昌','96'=>'万宁','97'=>'东方','A25'=>'定安','A26'=>'屯昌','A27'=>'澄迈','A28'=>'临高','A30'=>'白沙','A31'=>'昌江',
		 * 'A33'=>'乐东','A34'=>'陵水','A35'=>'保亭','A36'=>'琼中','A37'=>'西沙','A38'=>'南沙','A39'=>'中沙',)),
		 */
		List<City> hainan = new ArrayList<City>();
		hainan.add(new City(1, "海口"));
		hainan.add(new City(2, "三亚"));
		hainan.add(new City(91, "五指山"));
		hainan.add(new City(92, "琼海"));
		hainan.add(new City(93, "儋州"));
		hainan.add(new City(95, "文昌"));
		hainan.add(new City(96, "万宁"));
		hainan.add(new City(97, "东方"));
		hainan.add(new City("A25", "定安"));
		hainan.add(new City("A26", "屯昌"));
		hainan.add(new City("A27", "澄迈"));
		hainan.add(new City("A28", "临高"));
		hainan.add(new City("A30", "白沙"));
		hainan.add(new City("A31", "昌江"));
		hainan.add(new City("A33", "乐东"));
		hainan.add(new City("A34", "陵水"));
		hainan.add(new City("A35", "保亭"));
		hainan.add(new City("A36", "琼中"));
		hainan.add(new City("A37", "西沙"));
		hainan.add(new City("A38", "南沙"));
		hainan.add(new City("A39", "中沙"));
		provinces.add(new Province(46, "海南", hainan));

		/*
		 * '50'=>array('name'=>'重庆','city'=>array('1'=>'万州','2'=>'涪陵','3'=>'渝中','4'=>'大渡口','5'=>'江北','6'=>'沙坪坝','7'=>'九龙坡','8'=>'南岸','9'=>'北碚','10'=>'万盛',
		 * '11'=>'双桥','12'=>'渝北','13'=>'巴南','21'=>'长寿','22'=>'綦江','23'=>'潼南','24'=>'铜梁','25'=>'大足','26'=>'荣昌','27'=>'璧山','28'=>'梁平','29'=>'城口','30'=>'丰都',
		 * '31'=>'垫江','32'=>'武隆','33'=>'忠县','34'=>'开县','35'=>'云阳','36'=>'奉节','37'=>'巫山','38'=>'巫溪','39'=>'黔江','40'=>'石柱',
		 * '41'=>'秀山','42'=>'酉阳','43'=>'彭水','81'=>'江津','82'=>'合川','83'=>'永川','84'=>'南川',)),
		 */
		List<City> chongqing = new ArrayList<City>();
		chongqing.add(new City(1, "万州"));
		chongqing.add(new City(2, "涪陵"));
		chongqing.add(new City(3, "渝中"));
		chongqing.add(new City(4, "大渡口"));
		chongqing.add(new City(5, "江北"));
		chongqing.add(new City(6, "沙坪坝"));
		chongqing.add(new City(7, "九龙坡"));
		chongqing.add(new City(8, "南岸"));
		chongqing.add(new City(9, "北碚"));
		chongqing.add(new City(10, "万盛"));
		chongqing.add(new City(11, "双桥"));
		chongqing.add(new City(12, "渝北"));
		chongqing.add(new City(13, "巴南"));
		chongqing.add(new City(21, "长寿"));
		chongqing.add(new City(22, "綦江"));
		chongqing.add(new City(23, "潼南"));
		chongqing.add(new City(24, "铜梁"));
		chongqing.add(new City(25, "大足"));
		chongqing.add(new City(26, "荣昌"));
		chongqing.add(new City(27, "璧山"));
		chongqing.add(new City(28, "梁平"));
		chongqing.add(new City(29, "城口"));
		chongqing.add(new City(30, "丰都"));
		chongqing.add(new City(31, "垫江"));
		chongqing.add(new City(32, "武隆"));
		chongqing.add(new City(33, "忠县"));
		chongqing.add(new City(34, "开县"));
		chongqing.add(new City(35, "云阳"));
		chongqing.add(new City(36, "奉节"));
		chongqing.add(new City(37, "巫山"));
		chongqing.add(new City(38, "巫溪"));
		chongqing.add(new City(39, "黔江"));
		chongqing.add(new City(40, "石柱"));
		chongqing.add(new City(41, "秀山"));
		chongqing.add(new City(42, "酉阳"));
		chongqing.add(new City(43, "彭水"));
		chongqing.add(new City(81, "江津"));
		chongqing.add(new City(82, "合川"));
		chongqing.add(new City(83, "永川"));
		chongqing.add(new City(84, "南川"));
		provinces.add(new Province(50, "重庆", chongqing));

		/*
		 * '51'=>array('name'=>'四川','city'=>array('1'=>'成都','3'=>'自贡','4'=>'攀枝花','5'=>'泸州','6'=>'德阳','7'=>'绵阳','8'=>'广元','9'=>'遂宁','10'=>'内江',
		 * '11'=>'乐山','13'=>'南充','14'=>'眉山','15'=>'宜宾','16'=>'广安','17'=>'达州','18'=>'雅安','19'=>'巴中','20'=>'资阳','32'=>'阿坝','33'=>'甘孜','34'=>'凉山',)),
		 */
		List<City> sc = new ArrayList<City>();
		sc.add(new City(1, "成都"));
		sc.add(new City(3, "自贡"));
		sc.add(new City(4, "攀枝花"));
		sc.add(new City(5, "泸州"));
		sc.add(new City(6, "德阳"));
		sc.add(new City(7, "绵阳"));
		sc.add(new City(8, "广元"));
		sc.add(new City(9, "遂宁"));
		sc.add(new City(10, "内江"));
		sc.add(new City(11, "乐山"));
		sc.add(new City(13, "南充"));
		sc.add(new City(14, "眉山"));
		sc.add(new City(15, "宜宾"));
		sc.add(new City(16, "广安"));
		sc.add(new City(17, "达州"));
		sc.add(new City(18, "雅安"));
		sc.add(new City(19, "巴中"));
		sc.add(new City(20, "资阳"));
		sc.add(new City(32, "阿坝"));
		sc.add(new City(33, "甘孜"));
		sc.add(new City(34, "凉山"));
		provinces.add(new Province(51, "四川", sc));

		return provinces;
	}

}
